﻿using LangRenGameLib.Room.InfoClass;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace LangRenGameLib.Room
{
    /// <summary>
    /// 游戏规则的总类(板子的总父类)
    /// </summary>
    class Room
    {
        /// <summary>
        /// 板子的基本信息
        /// </summary>
        public RoomBaseInfo BaseInfo;

        /// <summary>
        /// 板子的自定义规则列表
        /// </summary>
        public List<Rule> RuleList;

        /// <summary>
        /// 板子的固定规则
        /// </summary>
        public RoomRule Rule;

        /// <summary>
        /// 房间内的玩家
        /// </summary>
        public PlayerInRoom Players;

        /// <summary>
        /// 游戏的进程
        /// </summary>
        public RunTime GameRun;

        /// <summary>
        /// 房间的ID*用于获得房间*
        /// </summary>
        public int RoomID;

        /// <summary>
        /// 初始化
        /// </summary>
        public virtual void Init()
        {
            Players.Owner = this;
            GameRun.Owner = this;
        }
    }
}
